"""bbs_server URL Configuration

The `urlpatterns` list routes URLs to views. For more information please see:
    https://docs.djangoproject.com/en/3.2/topics/http/urls/
Examples:
Function views
    1. Add an import:  from my_app import views
    2. Add a URL to urlpatterns:  path('', views.home, name='home')
Class-based views
    1. Add an import:  from other_app.views import Home
    2. Add a URL to urlpatterns:  path('', Home.as_view(), name='home')
Including another URLconf
    1. Import the include() function: from django.urls import include, path
    2. Add a URL to urlpatterns:  path('blog/', include('blog.urls'))
"""
from django.contrib import admin
from django.contrib.staticfiles.urls import staticfiles_urlpatterns
from django.conf.urls.static import static
from django.urls import path

from bbs_server import settings, views


urlpatterns = [
    path('',  views.home),
    path('admin/', admin.site.urls),
    path('hello/', views.hello),
    path('query_post/', views.query_post),
    path('get_post/', views.get_post),
    path('query_draft/', views.query_draft),
    path('get_essay/', views.get_essay),
    path('add_post/', views.add_post),
    path('update_post/', views.update_post),
    path('register/', views.register),
    path('login/', views.login),
    path('update_user/', views.update_user),
    path('get_user/', views.get_user),
    path('upload_media/', views.upload_media),
    path('follow/', views.follow),
    path('get_following/', views.get_following),
    path('get_followed/', views.get_followed),
    path('add_block/', views.add_block),
    path('get_block/', views.get_block),
    path('comment_post/', views.comment_post),
    path('comment_get/', views.comment_get),
    path('like/', views.like),
    path('add_notice/', views.add_notice),
    path('read_notice/', views.read_notice),
    path('get_notice/', views.get_notice),
]

urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)